﻿<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:ribbon="clr-namespace:Microsoft.Windows.Controls.Ribbon;assembly=RibbonControlsLibrary">

    <Style TargetType="{x:Type ribbon:Ribbon}">
        <Setter Property="Background" Value="{DynamicResource MenuBackground}" />
    </Style>
    
    <Style TargetType="{x:Type ribbon:RibbonTab}">
        <Setter Property="HeaderTemplate">
            <Setter.Value>
                <DataTemplate>
                    <Border>
                        <ContentPresenter>
                            <ContentPresenter.Content>
                                <TextBlock FontFamily="Tahoma" Margin="0 0 0 5" FontSize="11" FontStyle="{DynamicResource {x:Static SystemFonts.MenuFontStyleKey}}" 
                                           FontWeight="{DynamicResource {x:Static SystemFonts.MenuFontWeightKey}}" Foreground="{DynamicResource TopMenuItemForeground}"
                                           Text="{TemplateBinding Content}"/>
                            </ContentPresenter.Content>
                        </ContentPresenter>
                    </Border>
                </DataTemplate>
            </Setter.Value>
        </Setter>
        <Style.Triggers>
            <Trigger Property="IsSelected" Value="True">
                <Setter Property="HeaderTemplate">
                    <Setter.Value>
                        <DataTemplate>
                            <Border>
                                <ContentPresenter>
                                    <ContentPresenter.Content>
                                        <TextBlock FontFamily="Tahoma" Margin="0 0 0 5" FontSize="11" FontStyle="{DynamicResource {x:Static SystemFonts.MenuFontStyleKey}}" 
                                           FontWeight="{DynamicResource {x:Static SystemFonts.MenuFontWeightKey}}" Foreground="{DynamicResource MenuItemBackground}"
                                           Text="{TemplateBinding Content}"/>
                                    </ContentPresenter.Content>
                                </ContentPresenter>
                            </Border>
                        </DataTemplate>
                    </Setter.Value>
                </Setter>
            </Trigger>
        </Style.Triggers>
    </Style>

</ResourceDictionary>